<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:p="http://primefaces.org/ui"
	template="#{jsfbootTheme.template.content}">

	<ui:define name="title">
		帮助文档
	</ui:define>

	<ui:define name="head">
		<style type="text/css">
		.docs h1 {
			margin-top: 30px;
		}
		
		.docs p, .docs li {
			line-height: 1.5;
		}
		
		.docs pre {
			font-family: monospace;
			background-color: #dee4e9;
			color: #757575;
			padding: 1em;
			font-size: 14px;
			border-radius: 3px;
			overflow: auto;
		}
		
		.video-container {
			position: relative;
			width: 100%;
			height: 0;
			padding-bottom: 56.25%;
		}
		
		.video-container iframe {
			position: absolute;
			top: 0;
			left: 0;
			width: 100%;
			height: 100%;
		}
		</style>
	</ui:define>

	<ui:define name="content">
		<div class="ui-g-3">
			<div class="card ClearPadding AlignHeight ui-fluid">
				<p:tree value="#{adminHelpView.catalogTree}" var="cat" dynamic="true"
						styleClass="ClearBorder" selectionMode="single">
					<p:treeNode type="default">
						<p:link value=" #{cat.title}" outcome="#{adminHelpView.helpOutcome}">
							<f:param name="page" value="#{cat.fullPath}"/>
						</p:link>
					</p:treeNode>
				</p:tree>
			</div>
		</div>
		<div class="ui-g-9">
			<div class="card AlignHeight ClearPadding">
				<h:form>
					<p:breadCrumb homeDisplay="false" model="#{adminHelpView.viewPage.breadCrumb}">
					</p:breadCrumb>
				</h:form>
				<div class="card docs">
					<p:outputPanel rendered="#{adminHelpView.viewPage != null}">
						<p:outputPanel rendered="#{adminHelpView.viewPage.type == 'INCLUDE'}">
							<ui:include src="#{adminHelpView.viewPage.viewUrl}"/>
						</p:outputPanel>
						<p:outputPanel rendered="#{adminHelpView.viewPage.type == 'IFRAME'}">
							<iframe src="#{adminHelpView.viewPage.viewUrl}" class="Wid100 ClearBorder"/>
						</p:outputPanel>
						<p:outputPanel rendered="#{adminHelpView.viewPage.type == 'REDIRECT'}">
							暂时没有查看 REDIRECT 类型的页面。
						</p:outputPanel>
					</p:outputPanel>
					
					<p:outputPanel rendered="#{adminHelpView.viewPage == null}">
						不好意思，不能提供任何帮助信息。
					</p:outputPanel>
				</div>
			</div>
		</div>
	</ui:define>

</ui:composition>